package maven.demo4;

public class Trunk extends Car {
    public Trunk(int num, String name, int loads, int rent) {
        this.setNum(num);
        this.setName(name);
        this.setLoads(loads);
        this.setRent(rent);
    }

    public String toString() {
        return (num + "\t" + name + "\t" + "载货" + loads + "吨" + "\t\t" + rent);
    }
}
